package com.example.wto.myapplication;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

/**
 * Created by wto on 4/15/2017.
 */

public class UtilSqlHelper extends SQLiteOpenHelper
{

    public UtilSqlHelper(Context context, String name, SQLiteDatabase.CursorFactory factory, int version)
    {
        super(context, name, factory, version);
    }

    @Override
    public void onCreate(SQLiteDatabase db)
    {
        db.execSQL("create table teacher_table (s_id text,t_id text,name text,primary key(s_id,t_id))");
        db.execSQL("create table week_teacher_table (s_id text,t_id text,week_name text,order_t text,week_one text,week_two text,week_three text,week_four text,week_five text,week_six text,week_seven text,primary key(s_id,t_id,week_name))");
    }

    @Override
    public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion)
    {

    }
}
